import {useState} from "react";
import {AtAvatar, AtCurtain, AtButton, AtDivider} from "taro-ui";
import {Image, Text, View} from "@tarojs/components";

import './index.scss'
import TabBar from "../../components/tabBar";

export default function (){

  const [isShow,setIsShow] = useState<boolean>(false)

  return (
    <View className='tabBar-page'>
      <View className='tabBar-page-content'>
        <View className='tabBar-avatar'>
          <View onClick={() => setIsShow(true)}>
            <AtAvatar
              size='large'
              circle
              image='https://img0.baidu.com/it/u=240825848,1234988590&fm=26&fmt=auto&gp=0.jpg'
            />
          </View>
          <AtCurtain
            closeBtnPosition='top'
            onClose={() => {setIsShow(false)}}
            isOpened={isShow}
          >
            <Image
              style='width:100%;height:250px;'
              src='https://img0.baidu.com/it/u=240825848,1234988590&fm=26&fmt=auto&gp=0.jpg'
            />
          </AtCurtain>
        </View>
        <AtDivider />

      </View>
      <TabBar current={1} />
    </View>
  )
}

